package com.sz.common.pay.pingan.exception;

import com.sz.common.pay.common.DateGenerator;
import com.sz.common.pay.pingan.entity.common.CommonHeadResponse;

/**
 * Function: TODO: ADD FUNCTION <br>
 *
 * @author: siqishangshu <br>
 * @date: 2017-11-01 10:28:00
 */

public class PayException extends Throwable {
    private static final long serialVersionUID = 5162710183389028794L;
    private CommonHeadResponse errorMessage;

    /**
     * Constructs a {@code PayException} with no detail message.
     */
    public PayException() {
        super();
    }

    /**
     * Constructs a {@code PayException} with no detail message.
     */
    public PayException(String message) {
        super(message);
        errorMessage = new CommonHeadResponse();
        errorMessage.setTranDateTime(DateGenerator.getyyyyMMdd_HHmmss());
    }

    public CommonHeadResponse getErrorMessage() {
        return errorMessage;
    }

    public void setErrorMessage(CommonHeadResponse errorMessage) {
        this.errorMessage = errorMessage;
    }

}
